<!-- 富文本编辑器 -->
<script type="text/javascript" charset="utf-8" src="__PUBLIC__/Admin/vendor/plugins/ueditor/ueditor.config.js"></script>
<script type="text/javascript" charset="utf-8" src="__PUBLIC__/Admin/vendor/plugins/ueditor/ueditor.all.js"> </script>
<script type="text/javascript" charset="utf-8" src="__PUBLIC__/Admin/vendor/plugins/ueditor/lang/zh-cn/zh-cn.js"></script>
<script type="text/javascript" charset="utf-8" src="__PUBLIC__/Admin/js/ajaxfileupload.js"></script>
<style type="text/css">
  .w240{width: 240px;}
  .sml-240{padding-left: 240px;}
</style>

<div id="content" class="">
        <div class="row">
          <div class="col-md-12">
            <!-- Input Fields -->
            <div class="panel">
              <div class="panel-heading">
                <span class="panel-title">关于我们设置</span>
              </div>
              <div class="admin-form theme-primary mw1000 center-block" style="padding-bottom: 175px; margin-top:30px;">
              <div class="panel heading-border panel-primary">
                <form method="post" action="{:U('System/doAboutUs')}"  >


                <div style="margin-top: 30px;">
                  <div><h3>上传Banner图片</h3></div>
                  <span class="fileupload-preview thumbnail m5" >
                    <img src="{$aboutUs['bannerImg']}" class="img-responsive" id="about-us-banner">
                  </span>

                  <input type="file" class="gui-file" style="width:0px" name="aboutUs" id="about-us" onchange="ajaxuploadImg('about-us','about-us-banner-src','{:U('Ajax/uploadImg')}','about-us-banner');">
                  <input type="hidden" id="about-us-banner-src" name="bannerSrc" value="{$aboutUs['bannerImg']}">
                  <span class="fileupload-preview  m5 pull-right"><button type="button" onclick="getinputclick('about-us');" class="btn active btn-primary btn-block">上传Banner图片</button></span>
                </div>


                <div class="row" style="margin-top: 50px;">
                  <div style="margin-left: 15px;"><h3>上传配图</h3></div>
                  <div class="col-md-8">
                    <span class="fileupload-preview thumbnail m5" >
                        <img src="{$aboutUs['img']}" class="img-responsive" id="about-us-desc-img">
                    </span>

                    <input type="file" class="gui-file" style="width:0px" name="aboutUsImg" id="about-us-img" onchange="ajaxuploadImg('about-us-img','about-us-img-src','{:U('Ajax/uploadImg')}','about-us-desc-img');">
                    <input type="hidden" id="about-us-img-src" name="imgSrc" value="{$aboutUs['img']}">
                  </div>
                  <div class="col-md-4">
                    <span class="fileupload-preview  m5 pull-right"><button type="button" onclick="getinputclick('about-us-img');" class="btn active btn-primary btn-block">上传配图</button></span>
                  </div>
                  
                </div>

                <div class="section">
                    <h3>关于我们：</h3>
                    <textarea id="editor" style="height:300px;" name="aboutUsText">{$aboutUs['content']}</textarea>
                </div>
              </div>


              <div class="panel-footer text-right">
                <button type="submit" class="button btn-primary">提交</button>
                <button type="reset" class="button btn-primary">清空</button>
              </div>
                  <!-- end .form-footer section -->

              </form>

              </div>

            </div>
            </div>
          </div>
        </div>
</div>


<script type="text/javascript">
  var ue = UE.getEditor('editor');

  function getinputclick(id){
      var dom = $("#"+id);
      dom.click();
  }

</script>
